package com.flyco.modules.stm.entity;

import java.io.Serializable;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.TableField;
import com.flyco.common.aspect.annotation.Dict;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;
import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.format.annotation.DateTimeFormat;
import com.flyco.poi.excel.annotation.Excel;

/**
 * @Description: 库存流水
 * @Author: flyco
 * @Date:   2020-12-07
 * @Version: V1.0
 */
@Data
@TableName("stm_stock_record")
@EqualsAndHashCode(callSuper = false)
@Accessors(chain = true)
@ApiModel(value="stm_stock_record对象", description="库存流水")
public class StmStockRecord {
    
	/**id*/
	@TableId(type = IdType.AUTO)
    @ApiModelProperty(value = "id")
	private Long id;
	/**店铺id*/
	@Excel(name = "店铺id", width = 15)
    @ApiModelProperty(value = "店铺id")
	private Long storeId;
	/**商品id*/
	@Excel(name = "商品id", width = 15)
    @ApiModelProperty(value = "商品id")
	private Long productId;
	/**商品货号*/
	@Excel(name = "商品货号", width = 15)
    @ApiModelProperty(value = "商品货号")
	private String productSn;
	/**库存id*/
	@Excel(name = "库存id", width = 15)
    @ApiModelProperty(value = "库存id")
	private Long stockId;
	/**sku编码*/
	@Excel(name = "sku编码", width = 15)
    @ApiModelProperty(value = "sku编码")
	private String skuCode;
	/**数量*/
	@Excel(name = "数量", width = 15)
    @ApiModelProperty(value = "数量")
	private Integer quantity;
	/**原始库存*/
	@Excel(name = "原始库存", width = 15)
    @ApiModelProperty(value = "原始库存")
	private Integer oldStock;
	/**出入库类别：stock_in 入库，stock_out 出库*/
	@Excel(name = "出入库类别：stock_in 入库，stock_out 出库", width = 15)
    @ApiModelProperty(value = "出入库类别：stock_in 入库，stock_out 出库")
	@Dict(dicCode = "inout_type")
	private String inoutType;
	/**库存类别*/
	@Excel(name = "库存类别", width = 15)
    @ApiModelProperty(value = "库存类别")
	@Dict(dicCode = "stock_type")
	private String stockType;
	/**业务类型*/
	@Excel(name = "业务类型", width = 15)
    @ApiModelProperty(value = "业务类型")
	@Dict(dicCode = "stock_biz_type")
	private String bizType;
	/**来源类型*/
	@Excel(name = "来源类型", width = 15)
    @ApiModelProperty(value = "来源类型")
	@Dict(dicCode = "stock_source_type")
	private String sourceType;
	/**来源ID*/
	@Excel(name = "来源ID", width = 15)
    @ApiModelProperty(value = "来源ID")
	private String sourceId;
	/**库存变化原因*/
	@Excel(name = "库存变化原因", width = 15)
    @ApiModelProperty(value = "库存变化原因")
	private String changeReason;
	/**版本号*/
	@Excel(name = "版本号", width = 15)
    @ApiModelProperty(value = "版本号")
	private Integer version;
	/**创建人*/
	@Excel(name = "创建人", width = 15)
    @ApiModelProperty(value = "创建人")
	private String createBy;
	/**创建时间*/
	@Excel(name = "创建时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "创建时间")
	private Date createTime;
	/**更新人*/
	@Excel(name = "更新人", width = 15)
    @ApiModelProperty(value = "更新人")
	private String updateBy;
	/**更新时间*/
	@Excel(name = "更新时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
	@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
    @ApiModelProperty(value = "更新时间")
	private Date updateTime;
}
